package pers.lws.erp.common.emum;

/**
 * @author liuws
 * @create 2020-07-03 11:59
 */
public enum MsgStatusEmum {

    /**
     * 登陆状态
     */
    USER_LOGIN_NAME_ERROR("用户不存在！"),
    USER_LOGIN_PASS_ERROR("密码错误！"),
    USER_LOGIN_SUCCESS("登陆成功！"),
    USER_LOGIN_ERROR("登陆失败！"),
    SYS_DEFAULT_ERROR(-999,"系统发生错误啦，请联系管理员！"),
    SYS_UNAUTH(401, "冒昧问一句，宁配吗？"),

    //添加
    ADD_SUCCESS("添加成功！"),
    ADD_ERROR("添加失败！"),

    //删除
    DELETE_SUCCESS("删除成功！"),
    DELETE_ERROR("删除失败！"),

    //修改
    UPDATE_SUCCESS("修改成功！"),
    UPDATE_ERROR("修改失败！"),

    //分配
    DISPATCH_SUCCESS("分配成功！"),
    DISPATCH_ERROR("分配失败！"),

    //提交
    COMMIT_SUCCESS("提交成功！"),
    COMMIT_ERROR("提交失败！"),

    //保存
    SAVE_SUCCESS("保存成功！"),
    SAVE_ERROR("保存失败！"),

    //其他
    OTHER_SUCCESS("成功！"),
    OTHER_ERROR("失败！");

    //状态码
    private Integer code;
    //提示信息
    private String msg;

    MsgStatusEmum(String msg) {
        this.msg = msg;
    }

    MsgStatusEmum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
